package com.uobgroup.ews.uam.core.dao;

import java.util.List;

import com.uobgroup.ews.uam.core.domain.Reference;
import com.uobgroup.ews.uam.core.domain.UAMRole;


public interface UAMRoleDao extends GenericDao<UAMRole> {
   public long count();

   public List<UAMRole> findAll(int firstResult, int maxResults);
   
   /**
    * find the roles by role name
    * @author ndduy
    * @param name
    * @return {@link List}
    */
   public List<UAMRole> findByName(String name);
   public Boolean IsAssignProfile(Long RoleId);
   public Boolean IsExistSecurityGroup(UAMRole uamRole);
   
   /**
    * @author dongn
    */
   public long countRoleThatHasRoleTypeReference(Reference roleType);
   
   public long countRoleThatHasProcessingCentreReference(Reference processingCentre);
   
   public long countRoleThatHasDepartmentReference(Reference department);
}
